body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: #87CEEB;
}

canvas {
    display: block;
}

.menu-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, #87CEEB 0%, #98D8E8 50%, #B0E2FF 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    font-family: 'Comic Sans MS', cursive, sans-serif;
}

.game-title {
    font-size: 4rem;
    color: #FF6B6B;
    text-shadow: 3px 3px 0px #FF4757, 6px 6px 10px rgba(0,0,0,0.3);
    margin: 0;
    animation: bounce 2s infinite;
}

.game-subtitle {
    font-size: 1.5rem;
    color: #2C3E50;
    margin: 10px 0 40px 0;
    font-style: italic;
}

.difficulty-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 30px 0;
    gap: 10px;
}

.difficulty-container label {
    font-size: 1.5rem;
    color: #2C3E50;
    margin-bottom: 15px;
    font-weight: bold;
}

.slider-wrap {
    position: relative;
    width: 320px;
    padding-top: 28px; /* space for bubble */
}

.difficulty-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 12px;
    border-radius: 999px;
    background: linear-gradient(90deg, #4CAF50 0%, #FFC107 50%, #FF4757 100%);
    outline: none;
    margin: 0;
    position: relative;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.2);
}

/* WebKit thumb */
.difficulty-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 28px;
    height: 28px;
    background: radial-gradient(circle at 30% 30%, #fff, #ffecec 40%, #ffd3d3 100%);
    border: 3px solid #FF6B6B;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
    transition: transform 0.15s ease;
}
.difficulty-slider:active::-webkit-slider-thumb { transform: scale(1.1); }

/* Firefox */
.difficulty-slider::-moz-range-track {
    height: 12px;
    border-radius: 999px;
    background: linear-gradient(90deg, #4CAF50 0%, #FFC107 50%, #FF4757 100%);
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.2);
}
.difficulty-slider::-moz-range-thumb {
    width: 28px;
    height: 28px;
    background: radial-gradient(circle at 30% 30%, #fff, #ffecec 40%, #ffd3d3 100%);
    border: 3px solid #FF6B6B;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
    transition: transform 0.15s ease;
}
.difficulty-slider:active::-moz-range-thumb { transform: scale(1.1); }

/* Slider ticks (visual) */
.slider-wrap::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -8px;
    height: 8px;
    background:
      radial-gradient(circle, #2C3E50 40%, transparent 41%) 0 0/25% 100% repeat-x;
    opacity: 0.25;
}

/* Value bubble */
.difficulty-bubble {
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    background: #2C3E50;
    color: #fff;
    font-size: 0.9rem;
    padding: 6px 10px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    white-space: nowrap;
    pointer-events: none;
}
.difficulty-bubble::after {
    content: "";
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #2C3E50;
}

.difficulty-labels {
    display: flex;
    justify-content: space-between;
    width: 300px;
    font-size: 1rem;
    color: #2C3E50;
}

.start-button {
    font-size: 2rem;
    padding: 15px 40px;
    background: linear-gradient(45deg, #FF6B6B, #FF4757);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    font-family: inherit;
    font-weight: bold;
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 30px;
}

.start-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 107, 107, 0.6);
}

.start-button:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(255, 107, 107, 0.4);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}